.dialog {
    position: fixed;
    top: 5%;
    left: calc(50% - 25rem);
    height: initial;
    max-height: 90%;
    width: 50rem;

    overflow: hidden;

    box-shadow: 0 2.5rem 5rem rgba(0,0,0,0.30), 0 2rem 1.5rem rgba(0,0,0,0.22);
    border-radius: 0.5rem;
    z-index: 4;
    box-sizing: border-box;
    animation: zoom .25s ease-in-out;
}

.dialog:empty {
    display: none;
}

.dialog.scroll {
    height: 90%;
}

.dialog > section {
    max-height: calc(90vh - 7.2rem);
    height: 100%;
    overflow-y: auto;
    position: relative;
}

.dialog > section > *:first-child:not(ul) {
    margin-top: 2rem;
}

.dialog > section > table {
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.dialog > section > *:not(ul.list):last-child {
    margin-bottom: 2rem;
}

.dialog > section > *:not(ul) {
    padding: 0 2rem;
}

.dialog > section > form > ul > li {
    padding: 0;
}

.dialog > section h3 {
    padding-top: 0;
}

.dialog > section h3 + h4 {
    opacity: 0.7;
    padding-top: 0.5rem;
}

.dialog > section form h3 {
    padding-bottom: 0;
}

/* List specific */
.dialog > section form ul.list li > .primary {
    left: 0;
}

@media screen and (max-width: 600px) {
    .dialog {
        width: 90%;
        min-height: 0;
        min-width: 0;
        left: 5%;
    }
}
